// @ts-ignore
/* eslint-disable */
import request from '@/utils/request.ts'

/** 此处后端没有提供注释 POST /order/createOrder */
export async function createOrder(body: API.BizOrderVo, options?: { [key: string]: any }) {
  return request<API.BaseResponseQRCodeDto>('/order/createOrder', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /order/list */
export async function findAllOrders(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.findAllOrdersParams,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseListBizOrder>('/order/list', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 POST /order/payNotify */
export async function payNotify(options?: { [key: string]: any }) {
  return request<any>('/order/payNotify', {
    method: 'POST',
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /order/payResult */
export async function payResult(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.payResultParams,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponsePayRecordDto>('/order/payResult', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /order/requestPay */
export async function requestPay(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.requestPayParams,
  options?: { [key: string]: any }
) {
  return request<any>('/order/requestPay', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}
